#include "mainwindow.h"
#include "floatingwindow.h"

#include <QApplication>
#include <QLocale>
#include <QTranslator>
#include <QDockWidget>
#include <QFile>
#include <Qt>

int main(int argc, char *argv[])
{
    QApplication a(argc, argv);

    QTranslator translator;
    const QStringList uiLanguages = QLocale::system().uiLanguages();
    for (const QString &locale : uiLanguages) {
        const QString baseName = "desktopTools_" + QLocale(locale).name();
        if (translator.load(":/i18n/" + baseName)) {
            a.installTranslator(&translator);
            break;
        }
    }
    QFile Stylefile(":/common-qss-style-files-master/Light Blue/stylesheet.qss");
    if (Stylefile.open(QFile::ReadOnly)) {
        QString styleSheet = QLatin1String(Stylefile.readAll());
        a.setStyleSheet(styleSheet);
    }
    MainWindow w;
    w.show();
    return a.exec();
}
